﻿cmake_minimum_required(VERSION 2.8)
project(mediaServer)
file(GLOB_RECURSE hdrs RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} *.h)
file(GLOB_RECURSE srcs RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} *.cpp)
add_executable(${PROJECT_NAME} ${srcs} ${hdrs})
set_target_properties(${PROJECT_NAME} PROPERTIES OUTPUT_NAME "${PROJECT_NAME}$<$<CONFIG:Debug>:D>")
if(BUILD_DLL)
  add_definitions(-DBUILD_DLL)
  target_link_libraries(${PROJECT_NAME} liveMedia)
else()
  target_link_libraries(${PROJECT_NAME} UsageEnvironment groupsock BasicUsageEnvironment liveMedia ${SSL_LIBRARIES})
endif()
install(TARGETS ${PROJECT_NAME} RUNTIME DESTINATION bin)
